import { createApp } from 'vue'
import App from './App.vue'
import { setupRouter } from './router/index'
import { setupStore } from '@/store/index'
import setupDirectives from '@/utils/directives/index'
// import { store } from './store/index'
import elementPlus from './plugins/element-plus' // 配置element-plus插件
import '@/assets/iconfont/iconfont.css'
import '@/assets/iconfont/iconfont.js'

// 托拉拽组件使用
import formCreate from '@form-create/element-ui'
import FcDesigner from '@form-create/designer'

// import.meta.env

const app = createApp(App)
setupStore(app) // pinia引用方式一
setupRouter(app)
setupDirectives(app)
app.use(elementPlus)
app.use(formCreate)
app.use(FcDesigner)
app.mount('#app')

// createApp(App)
//   .use(elementPlus)
//   .use(store) // pinia引用方式二
//   .use(router)
//   .use(formCreate)
//   .use(FcDesigner)
//   .mount('#app')
